1. Field of the Invention
The present invention relates to a method, an apparatus, and a program for processing red eyes, that detects red eyes from within facial images included in entire images.
2. Description of the Related Art
There are cases in which pupils (or portions of pupils) of people or animals, photographed by flash photography at night or in dark places, are photographed as being red or gold. For this reason, various methods for correcting the color of pupils, which have been photographed as being red or gold (herein after, cases in which pupils are photographed as being gold are also referred to as “red eye”), to normal pupil colors by digital image processing have been proposed (for example, in Japanese Unexamined Patent Publication No. 2000-013680). Japanese Unexamined Patent Publication No. 2000-013680 discloses a method and apparatus for automatically discriminating red eyes. This method and apparatus automatically discriminate red eyes based on colors, positions, and sizes of pupils within regions specified by operators. In addition, a method has also been proposed wherein: predetermined characteristic amounts are calculated for each pixel within a region specified by an operator; and portions having characteristics that correspond to pupil portions are selected as targets of correction (for example, in U.S. Pat. No. 7,024,035).
Further, detecting faces, then detecting red eyes within regions which have been detected as faces, instead of performing red eye detection and red eye correction within regions specified by operators, has also been proposed (for example, in U.S. Pat. No. 6,252,976).
In the method disclosed in U.S. Pat. No. 6,252,976, red eye detection is performed using uniform set conditions with respect to all facial images within images. However, there are differences in the frequency of red eye occurrence and the degree of red colors within red eyes, among individuals. Therefore, there is a problem that detection accuracy deteriorates if red eye detection is uniformly administered with respect to all facial images. For example, in the case that red eyes are detected from within facial images of people for whom red eye occurs easily and from within facial images of people for whom red eye does not occur easily using the same detection properties, there is a possibility that red eyes will not be detected, even if they are present within the former facial images. Alternatively, false positive detections, in which red eyes are detected within the latter facial images even though they are not present, may occur.